package net.zhengxinyun.performance.service.indicators;

import net.zhengxinyun.performance.entity.*;
import net.zhengxinyun.performance.filter.TownFilter;
import net.zhengxinyun.performance.filter.TownIndicatorsFilter;
import net.zhengxinyun.performance.filter.TownScoreFilter;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * Created by hyp1202 on 2018/11/22.
 */
public interface TownScoreService {

    List<Map<String, Object>> query(TownIndicatorsFilter filter, RolePerEntity roleright, UserEntity userEntity);

    String update(TownScoreEntity townScoreEntity);

    String insert(TownScoreEntity townScoreEntity);

    String delete(TownScoreEntity townScoreEntity);

    Integer getThreeTableCount(TownIndicatorsFilter townIndicatorsFilter);

    String setScore(TownIndicatorsFilter townIndicatorsFilter, List<TownIndicatorsFilter> list);

    String auditAllPass(List<TownIndicatorsFilter> list);

    String responsibleAllPass(List<TownIndicatorsFilter> list);

    String noPass(TownIndicatorsFilter townIndicatorsFilter);

    List<Map<String, Object>> queryForAudit(TownIndicatorsFilter filter);

    int getAuditCount(TownIndicatorsFilter townIndicatorsFilter);

    String setFirstFinalScore(TownIndicatorsFilter townIndicatorsFilter);
    String importTownScore(MultipartFile file);
    String importScore(List<TownEntity> lists,Long id,UserEntity user,String datetime);

    HashMap<String,Object> queryAfterImport(String indexId,String datetime);

    HashMap<String,Object>   queryTownIndexValue(String indexId, String townId, HttpServletRequest  request);


    List<TownIndicatorsFilter> getIndictScore(TownIndicatorsFilter filter);

    List<TownIndicatorsFilter> getExporScore(TownIndicatorsFilter filter);

    List<Map<String,Object>> queryIndexRank(String datetime);

    HashMap<String, String> getAllDepartmen ();

    /*
        单个指标分析
     */
    Map indexAnalyse(Long indexId,String dateTime);
    /*
        乡镇分析
     */
    HashMap<String,Object> townAnalyse(String townid,String datetime,Long indexId,int top ,int bad);


    /**
     * 历史数据
     */
    List TownHistoryData(Long indexId)
    ;

}
